
#include <string.h>

#include "ReaderISO15693.h"
#include <mh663/nfc663.h>
#include <mh663/iso15693.h>

int Reader_Read15963(CSN_T* csn){
	uint8_t uid[8];
	uint8_t maskval[8];
	uint8_t masklen = 0;
	uint8_t dsfid;
	pcd_config('V');
	uint8_t flag = BIT1 | BIT2 | AFI_FLAG | NB_SLOTS_FLAG;
	int ret = pcd_inventory(flag, 0, maskval, masklen, &dsfid, uid);
	if(ret){
		return -1;
	}
	
	if(csn){
		memcpy(csn->num, uid, 8);
		csn->nlen = 8;
	}
	csn->type = TAG_T_15693;
	return 0;
}




